package com.zsw.demo02;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.Map;

public class Data {
    public static void main(String[] args) {
        ArrayList<Map<String, Object>> objects = new ArrayList<>();

        HashMap<String, Object> hashmap = new HashMap<>();
        hashmap.put("name", "王五");
        hashmap.put("id", 12);
        hashmap.put("age", 18);
        objects.add(hashmap);

        HashMap<String, Object> hashmap1 = new HashMap<>();
        hashmap1.put("name", "张三");
        hashmap1.put("id", 25);
        hashmap1.put("age", 20);
        objects.add(hashmap1);

        for (Map<String, Object> map : objects) {
            System.out.println(map);
        }
    }

}
